package com.mes.md.controller;

import com.mes.md.util.OssUtil;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.multipart.MultipartFile;

/**
 * @Author hitsune
 * @Company kafu chino
 * @Description
 * @Time 2024/10/23 15:27
 */


@RestController
@RequestMapping("/oss")
public class OssController {
    @Autowired
    private OssUtil ossUtil;

    @PostMapping("/showImg")
    public String upload(MultipartFile file) {
        return ossUtil.uploadMultipartFile(file);
    }
}

